<div class="panel-heading">
	<h3>Latest Top-up Orders</h3>
</div>
<div class="panel-overview panel panel-body fadeIn">
	<div class="panel-body">
	@if ( $results->count() ) 
	<table class="table-overview table table-hover">
		<thead>
			<tr>
				<td class="text-left">{{ $list_id }}</td>  
				<td class="text-left">{{ $list_employee_name }}</td>
				<td class="text-left">{{ $list_ORDER_id }}</td>
				<td class="text-left">{{ $list_company }}</td>
				<td class="text-left">{{ $list_created_at }}</td>
				<td class="text-left">{{ $list_payment_method }}</td>
				<td class="text-left">{{ $list_topup_status }}</td> 
				<td class="text-left">{{ $list_action }}</td> 
			</tr>
		</thead>
		<tbody>
			@foreach($results as $key => $value)
				<tr>
					<td>{{ $value->id }}</td>
					<td>{{ $value->firstname }} {{ $value->lastname }}</td>
					<td>{{ $value->ORDER_id }}</td>
					<td>{{ $value->name }}</td>
					<td>{{ strtotime($value->created_at) ? date_format($value->created_at,"m/d/Y H:i:s") : '-' }}</td>
					<td>{{ $payment_method[$value->payment_method] }}</td>
					<td>{{ $topup_status_data[$value->topup_status] }}</td>
					<td><a class="btn-success btn" href="{{ URL::to('top-up') }}?filter_topup_id={{ $value->id }}&view_details=1">View</a></td>
				</tr>
			@endforeach  
		</tbody>
	</table>
@else
	No Results Found.
@endif
	</div>
</div>

<div class="panel-heading">
	<h3>For Checking Top-up Orders</h3>
</div>
<div class="panel-overview panel panel-body fadeIn">
	<div class="panel-body">
@if ( $results2->count() ) 
	<table class="table-overview table table-hover">
		<thead>
			<tr>
				<td class="text-left">{{ $list_id }}</td>  
				<td class="text-left">{{ $list_employee_name }}</td>
				<td class="text-left">{{ $list_ORDER_id }}</td>
				<td class="text-left">{{ $list_company }}</td>
				<td class="text-left">{{ $list_created_at }}</td>
				<td class="text-left">{{ $list_payment_method }}</td>
				<td class="text-left">{{ $list_topup_status }}</td> 
				<td class="text-left">{{ $list_action }}</td> 
			</tr>
		</thead>
		<tbody>
			@foreach($results2 as $key => $value)
				<tr>
					<td>{{ $value->id }}</td>
					<td>{{ $value->firstname }} {{ $value->lastname }}</td>
					<td>{{ $value->ORDER_id }}</td>
					<td>{{ $value->name }}</td>
					<td>{{ strtotime($value->created_at) ? date_format($value->created_at,"m/d/Y H:i:s") : '-' }}</td>
					<td>{{ $payment_method[$value->payment_method] }}</td>
					<td>{{ $topup_status_data[$value->topup_status] }}</td>
					<td><a class="btn-success btn" href="{{ URL::to('top-up') }}?filter_topup_id={{ $value->id }}&view_details=1">View</a></td>
				</tr>
			@endforeach  
		</tbody>
	</table>
@else
No Results Found.
@endif
	</div>
</div>


<div class="panel-heading">
	<h3>Pending Topup that are nearest to Cancel</h3>
</div>
<div class="panel-overview panel panel-body fadeIn">
	<div class="panel-body">
@if ( $results3->count() ) 
	<table class="table-overview table table-hover">
		<thead>
			<tr>
				<td class="text-left">{{ $list_id }}</td>  
				<td class="text-left">{{ $list_employee_name }}</td>
				<td class="text-left">{{ $list_ORDER_id }}</td>
				<td class="text-left">{{ $list_company }}</td>
				<td class="text-left">{{ $list_created_at }}</td>
				<td class="text-left">{{ $list_payment_method }}</td>
				<td class="text-left">{{ $list_topup_status }}</td> 
				<td class="text-left">{{ $list_action }}</td> 
			</tr>
		</thead>
		<tbody>
			@foreach($results3 as $key => $value)
				<tr>
					<td>{{ $value->id }}</td>
					<td>{{ $value->firstname }} {{ $value->lastname }}</td>
					<td>{{ $value->ORDER_id }}</td>
					<td>{{ $value->name }}</td>
					<td>{{ strtotime($value->created_at) ? date_format($value->created_at,"m/d/Y H:i:s") : '-' }}</td>
					<td>{{ $payment_method[$value->payment_method] }}</td>
					<td>{{ $topup_status_data[$value->topup_status] }}</td>
					<td><a class="btn-success btn" href="{{ URL::to('top-up') }}?filter_topup_id={{ $value->id }}&view_details=1">View</a></td>
				</tr>
			@endforeach  
		</tbody>
	</table>
@else
No Results Found.
@endif
	</div>
</div>


<div class="panel-heading">
	<h3>Nearest Cancel Order with No Topup Information</h3>
</div>
<div class="panel-overview panel panel-body fadeIn">
	<div class="panel-body">
@if ( $results4->count() ) 
	<table class="table-overview table table-hover">
		<thead>
			<tr>
				<td class="text-left">{{ $list_id }}</td>  
				<td class="text-left">{{ $list_employee_name }}</td>
				<td class="text-left">{{ $list_ORDER_id }}</td>
				<td class="text-left">{{ $list_company }}</td>
				<td class="text-left">{{ $list_created_at }}</td>
				<td class="text-left">{{ $list_payment_method }}</td>
				<td class="text-left">{{ $list_topup_status }}</td> 
				<td class="text-left">{{ $list_action }}</td> 
			</tr>
		</thead>
		<tbody>
			@foreach($results4 as $key => $value)
				<tr>
					<td>{{ $value->id }}</td>
					<td>{{ $value->firstname }} {{ $value->lastname }}</td>
					<td>{{ $value->ORDER_id }}</td>
					<td>{{ $value->name }}</td>
					<td>{{ strtotime($value->created_at) ? date_format($value->created_at,"m/d/Y H:i:s") : '-' }}</td>
					<td>{{ $payment_method[$value->payment_method] }}</td>
					<td>{{ $topup_status_data[$value->topup_status] }}</td>
					<td><a class="btn-success btn" href="{{ URL::to('top-up') }}?filter_topup_id={{ $value->id }}&view_details=1">View</a></td>
				</tr>
			@endforeach  
		</tbody>
	</table>
@else
No Results Found.
@endif
	</div>
</div>


<div class="panel-heading">
	<h3>Nearest Cancel Order with Cancel Topup</h3>
</div>
<div class="panel-overview panel panel-body fadeIn">
	<div class="panel-body">
@if ( $results5->count() ) 
	<table class="table-overview table table-hover">
		<thead>
			<tr>
				<td class="text-left">{{ $list_id }}</td>  
				<td class="text-left">{{ $list_employee_name }}</td>
				<td class="text-left">{{ $list_ORDER_id }}</td>
				<td class="text-left">{{ $list_company }}</td>
				<td class="text-left">{{ $list_created_at }}</td>
				<td class="text-left">{{ $list_payment_method }}</td>
				<td class="text-left">{{ $list_topup_status }}</td> 
				<td class="text-left">{{ $list_action }}</td> 
			</tr>
		</thead>
		<tbody>
			@foreach($results5 as $key => $value)
				<tr>
					<td>{{ $value->id }}</td>
					<td>{{ $value->firstname }} {{ $value->lastname }}</td>
					<td>{{ $value->ORDER_id }}</td>
					<td>{{ $value->name }}</td>
					<td>{{ strtotime($value->created_at) ? date_format($value->created_at,"m/d/Y H:i:s") : '-' }}</td>
					<td>{{ $payment_method[$value->payment_method] }}</td>
					<td>{{ $topup_status_data[$value->topup_status] }}</td>
					<td><a class="btn-success btn" href="{{ URL::to('top-up') }}?filter_topup_id={{ $value->id }}&view_details=1">View</a></td>
				</tr>
			@endforeach  
		</tbody>
	</table>
@else
No Results Found.
@endif
	</div>
</div>